<!DOCTYPE html>
<html lang="en">
<!--导入定义的变量-->
<#include "common/virs.ftl" />
<head>
    <meta charset="UTF-8">
    <title>归档</title>
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <meta name="keywords" content="hyblog,博客,杨德明,杨德明的个人博客,it,技术">
    <meta name="description" content="站长专注于java开发，高并发、高可用、分布式……">
    <link rel="shortcut icon" href="./static/pic/favicon.ico">
    <link rel="stylesheet" href="${layui_css}">
    <link rel="stylesheet" href="${main_css}">
    <!-- 字体 -->
    <link rel="stylesheet" href="${font_awesome_css}">
    <!--动画-->
    <link href="${animate_css}" rel="stylesheet">
</head>
<body>
<!--整体容器-->
<div class="hy-blog">

    <!--导航条导入-->
    <#include "templates/nav.html" />
    <!-- 主体内容 -->
    <div class="layui-container">
        <div class="layui-row layui-col-space15">
            <!--主体内容-->
            <!--文章主体区域-->
            <div class="layui-col-md8 animated fadeInLeft">
                <div class="archive-panel layui-col-xs12">
                    <div style="text-align: center;padding-top: 10px;"><h1>文章归档</h1></div>

                    <#list archiveMap?keys as key>
                        <div class="one-item layui-col-xs12">
                            <hr/>
                            <div class="archive-time layui-col-xs3"><h2>${key}</h2></div>
                            <div class="archive-content layui-col-xs9">
                                <ul>
                                    <#assign item = archiveMap[key]/>
                                    <#list item as article>
                                        <li style="margin: 4px 0">
                                            <a href="/details?aid=${article.aid}">
                                                ${article.createTime?string('dd')}日&emsp;&emsp;${article.title}
                                            </a>
                                        </li>
                                    </#list>
                                </ul>
                            </div>
                        </div>
                    </#list>

                    <div class="layui-col-xs12" style="padding-bottom: 20px;">
                        <hr/>
                    </div>

                </div>
            </div>

            <!--导入右侧辅助区域-->
            <#include "templates/right.html"/>

        </div>
    </div>
    <!-- 主体内容end -->


    <!--导入footer-->
    <#include "templates/foot.html" />
</div>
<script src="${layui_js}"></script>
<script>
    //config的设置是全局的
    layui.config({
        base: '/static/js/' //假设这是你存放拓展模块的根目录
    });
    layui.use(['element', 'carousel','util','common'], function () {
        var element = layui.element; //导航的hover效果、二级菜单等功能，需要依赖element模块
        var carousel = layui.carousel;
        var util = layui.util;
        var $ = layui.jquery;
        var common = layui.common;

        //绑定qq和微信点击事件，点击时弹出二维码
        common.bindQQ();
        common.bindWechat();
        //异步请求分类,标签,友链信息
        common.querycategory();
        common.querytag();
        common.queryfriendshiplink();

        //给【归档】添加layui-this的样式
        $("#nav-archive").addClass("layui-this");

        //监听导航点击
        element.on('nav(demo)', function (elem) {
            //console.log(elem)
            layer.msg(elem.text());
        });
        //执行
        util.fixbar({
            bar1: false
            ,click: 'top'
        });


    });
</script>
</body>
</html>